package com.qf.j2205.service.impl;


import com.qf.j2205.dao.RoleMapper;
import com.qf.j2205.entity.Role;
import com.qf.j2205.service.RoleService;
import com.qf.j2205.util.MybitesUtil;

import java.util.List;

/**
 * @ClassName RoleServiceImpl
 * @Description TODO
 * @Author Windy
 * @Date 2022/8/17 19:41
 * @Version 1.0
 **/
public class RoleServiceImpl implements RoleService {
    /**
     * 查询全部角色
     *
     * @return
     */
    public List<Role> findAll(){
        RoleMapper mapper = MybitesUtil.getSession().getMapper(RoleMapper.class);
        List<Role> lists = null;
        lists = mapper.findAll();
        MybitesUtil.closeAll();
        return lists;
    }
}
